<!-- eslint-disable -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta http-equiv="X-UA-Compatible" content="IE=8,IE=9;"/>
    <title>工具条</title>
    <link type="text/css" href="css/toolbar.css" rel="stylesheet"/>
    <link type="text/css" href="css/dialog.css" rel="stylesheet"/>
    <script type="text/javascript" src="js/md5.js"></script>
    <script type="text/javascript" src="js/jquery-1.6.2.js"></script>
    <script type="text/javascript" src="js/tools.js?v=1.0.0"></script>
    <script type="text/javascript">
        if(window.location.href.indexOf("cticloud") > 0){
            document.domain='cticloud.cn';
        }

        //*******************************动态加载agent toolbar.js文件*********************************
        var oHead = document.getElementsByTagName('head').item(0);
        var oScript = document.createElement("script");
        oScript.type = "text/javascript";
        oScript.src = window.location.protocol + "//" +agent_url + "/js/toolbar/toolbar.js?v=10.4.7";
        oScript.charset = "UTF-8";
        oHead.appendChild(oScript);
        if(oScript.readyState) { // IE
            oScript.onreadystatechange = function() {
                if(oScript.readyState == "loaded" || oScript.readyState == "complete") {
                    oScript.onreadystatechange = null;
                    if(showLoginTool){
                        $("#loginTool").show();
                    }
                }
            };
        } else { // Other
            oScript.onload = function() {
                if(showLoginTool){
                    $("#loginTool").show();
                }
            };
        }
    </script>
</head>
<body onunload="logoutByConfig()">
<div style="position:relative;left:0px;top:1px;height:100%;width: auto;background: #F0F0F0;border: solid 1px #ddd;">
    <span id="cnoTime" style="display: none;"></span>
    <table border="0" cellspacing="0" cellpadding="0" style="margin:0;width:100%;">
        <tr>
            <td>
                <div style="display: inline;">
                    <div id="idle_button" class="img" onclick="barClick('idle')" style="display: none;">
                        <div class="desc">置闲</div>
                        <a href="#">
                            <img src="images/toolbar/available/置闲.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-idle_button" class="img" >
                        <div class="desc">置闲</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/置闲.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="busy_button" class="img" onclick="barClick('busy')" style="display: none;">
                        <div class="desc">置忙</div>
                        <a href="#">
                            <img src="images/toolbar/available/置忙.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-busy_button" class="img" >
                        <div class="desc">置忙</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/置忙.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="little_rest_button" class="img" onclick="barClick('little_rest')" style="display: none;">
                        <div class="desc">小休</div>
                        <a href="#">
                            <img src="images/toolbar/available/小休.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-little_rest_button" class="img" >
                        <div class="desc">小休</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/小休.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="have_meals_button" class="img" onclick="barClick('have_meals')" style="display: none;">
                        <div class="desc">用餐</div>
                        <a href="#">
                            <img src="images/toolbar/available/用餐.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-have_meals_button" class="img" >
                        <div class="desc">用餐</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/用餐.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="train_button" class="img" onclick="barClick('train')" style="display: none;">
                        <div class="desc">培训</div>
                        <a href="#">
                            <img src="images/toolbar/available/培训.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-train_button" class="img" >
                        <div class="desc">培训</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/培训.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="rest_button" class="img" onclick="barClick('rest')" style="display: none;">
                        <div class="desc">休息</div>
                        <a href="#">
                            <img src="images/toolbar/available/休息.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-rest_button" class="img" >
                        <div class="desc">休息</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/休息.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="calling_button" class="img" onclick="barClick('calling')" style="display: none;">
                        <div class="desc">呼叫</div>
                        <a href="#">
                            <img src="images/toolbar/available/呼叫.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-calling_button" class="img" >
                        <div class="desc">呼叫</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/呼叫.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="axb_calling_button" class="img" onclick="barClick('axbCalling')" style="display: none;">
                        <div class="desc">axb呼叫</div>
                        <a href="#">
                            <img src="images/toolbar/available/呼叫.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-axb_calling_button" class="img" >
                        <div class="desc">axb呼叫</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/呼叫.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="callCancel_button" class="img" onclick="barClick('callCancel')" style="display: none;">
                        <div class="desc">取消外呼</div>
                        <a href="#">
                            <img src="images/toolbar/available/取消外呼.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-callCancel_button" class="img" >
                        <div class="desc">取消外呼</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/取消外呼.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="keep_button" class="img" onclick="barClick('keep')" style="display: none;">
                        <div class="desc">保持</div>
                        <a href="#">
                            <img src="images/toolbar/available/保持.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-keep_button" class="img" >
                        <div class="desc">保持</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/保持.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="keep_back_button" class="img" onclick="barClick('keep_back')" style="display: none;">
                        <div class="desc">保持接回</div>
                        <a href="#">
                            <img src="images/toolbar/available/保持接回.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-keep_back_button" class="img" >
                        <div class="desc">保持接回</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/保持接回.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="consulting_button" class="img" onclick="barClick('consulting')" style="display: none;">
                        <div class="desc">咨询</div>
                        <a href="#">
                            <img src="images/toolbar/available/咨询.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-consulting_button" class="img" >
                        <div class="desc">咨询</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/咨询.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="cancel_consulting_button" class="img" onclick="barClick('cancelConsulting')" style="display: none;">
                        <div class="desc">取消咨询</div>
                        <a href="#">
                            <img src="images/toolbar/available/取消咨询.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-cancel_consulting_button" class="img" >
                        <div class="desc">取消咨询</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/取消咨询.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="consulting_back_button" class="img" onclick="barClick('consulting_back')" style="display: none;">
                        <div class="desc">咨询接回</div>
                        <a href="#">
                            <img src="images/toolbar/available/咨询接回.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-consulting_back_button" class="img" >
                        <div class="desc">咨询接回</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/咨询接回.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="three_party_consultation_button" class="img" onclick="barClick('three_party_consultation')" style="display: none;">
                        <div class="desc">咨询三方</div>
                        <a href="#">
                            <img src="images/toolbar/available/咨询三方.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-three_party_consultation_button" class="img" >
                        <div class="desc">咨询三方</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/咨询三方.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="transfer_button" class="img" onclick="barClick('transfer')" style="display: none;">
                        <div class="desc">转接</div>
                        <a href="#">
                            <img src="images/toolbar/available/转接.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-transfer_button" class="img" >
                        <div class="desc">转接</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/转接.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="interactive_button" class="img" onclick="barClick('interactive')" style="display: none;">
                        <div class="desc">交互</div>
                        <a href="#">
                            <img src="images/toolbar/available/交互.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-interactive_button" class="img" >
                        <div class="desc">交互</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/交互.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="satisfaction_button" class="img" onclick="barClick('satisfaction')" style="display: none;">
                        <div class="desc">满意度</div>
                        <a href="#">
                            <img src="images/toolbar/available/满意度.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-satisfaction_button" class="img" >
                        <div class="desc">满意度</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/满意度.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="answer_button" class="img" onclick="barClick('answer')" style="display: none;">
                        <div class="desc">接听</div>
                        <a href="#">
                            <img src="images/toolbar/available/接听.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-answer_button" class="img" >
                        <div class="desc">接听</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/接听.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="refuse_button" class="img" onclick="barClick('refuse')" style="display: none;">
                        <div class="desc">拒接</div>
                        <a href="#">
                            <img src="images/toolbar/available/拒接.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-refuse_button" class="img" >
                        <div class="desc">拒接</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/拒接.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="hangUp_button" class="img" onclick="barClick('hangUp')" style="display: none;">
                        <div class="desc">挂断</div>
                        <a href="#">
                            <img src="images/toolbar/available/挂断.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-hangUp_button" class="img" >
                        <div class="desc">挂断</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/挂断.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="mute_button" class="img" onclick="barClick('mute')" style="display: none;">
                        <div class="desc">静音</div>
                        <a href="#">
                            <img src="images/toolbar/available/静音.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-mute_button" class="img" >
                        <div class="desc">静音</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/静音.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div class="img">&nbsp;</div>
                    <div id="cancel_mute_button" class="img" onclick="barClick('cancel_mute')" style="display: none;">
                        <div class="desc">取消静音</div>
                        <a href="#">
                            <img src="images/toolbar/available/取消静音.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-cancel_mute_button" class="img" >
                        <div class="desc">取消静音</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/取消静音.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="mobile_agent_button" class="img" onclick="barClick('mobile')" style="display: none; margin: 0px;">
                        <div class="desc">移动坐席</div>
                        <a href="#">
                            <img src="images/toolbar/available/置闲.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-mobile_agent_button" class="img" style="margin: 0px;">
                        <div class="desc">移动坐席</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/置闲.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="office_agent_button" class="img" onclick="barClick('office')" style="display: none; margin: 0px;">
                        <div class="desc">办公坐席</div>
                        <a href="#">
                            <img src="images/toolbar/available/置闲.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                    <div id="no-office_agent_button" class="img" style="margin: 0px;" >
                        <div class="desc">办公坐席</div>
                        <a href="#">
                            <img src="images/toolbar/notavailable/置闲.png" alt="Ballade" class="barImg">
                        </a>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td>
                <div id="nologin" style="display: block;">&nbsp;状态：离线</div>
            <div id="infos" style="display: none;">
               <span>
                <b> &nbsp;
                工号：<label id="_cno"></label>&nbsp;&nbsp;
                号码：<label id="_bindTel"></label>
                    <!--<span id="changeBindTel" type="button" value="" onclick="changeBindTel()"/>-->
                    <span id="agentChangeBindTel" onclick="changeAgentTel()"><img src="images/iconEdit01_01.png" /></span>&nbsp;&nbsp;
                状态：<label id="_statusInfo"></label>&nbsp;&nbsp;
                时长：<label id="timer"></label>&nbsp;&nbsp;
                <input type="hidden" id="lastTime" value="30"/>
                <!--下面是呼叫条显示号码的元素2022-5-10隐藏-->
                <label id="_phone" style="display: none"></label>&nbsp;&nbsp;
                <input id="prolongWrapup" type="button" value="延长整理" onclick="prolongWrapup()"/>
                   &nbsp;
                 <label id="_rasrSeat"></label>&nbsp;&nbsp;
                 <label id="_rasrCustomer"></label>
                    &nbsp;&nbsp;
                 <label id="_extenState"></label>

                 <label id="latencyLabel" style="margin-right: 15px;margin-left: 12px;"></label>
                 <label id="callCountLabel" style="margin-right: 15px;"></label>
                 <label id="validCallCountLabel" style="margin-right: 15px"></label>
                 <label id="validCallTotalTimeLabel"></label>
                 </b>
                </span>
            </div>
            </td>
        </tr>
        <tr style="width:100%;display:inline-block;border-top: inset;border-width: 1px;">
            <td>
                <div id="loginTool" style="display: none;">
                <span>
                    <b>
                     <span id="loginPlatformContainer">
                         登录平台：
                        <select id="loginPlatform" style="width:85px;">
                            <option value="main" selected>主平台</option>
                            <option value="reserve">副平台</option>
                        </select>
                     </span>
                    登录方式：
                    <select id="loginType" onchange="changeLoginType()" style="width:85px;">
                        <option value="1" selected>部门编号</option>
                        <option value="2">呼叫中心编号</option>
                    </select>
                    <span name="enterpriseTR" id="enterpriseTR" style="width: 170px;display: none">
                    呼叫中心编号：
                    <input style="width: 70px;" type="text" value="" id="enterpriseId"/>
                    座席号：
                    <input style="width: 50px;" type="text" value="" id="cno"/>
                    </span>
                    <span name="departmentTR" id="departmentTR" style="width: 170px;">
                    部门编号：
                    <input style="width: 70px;" type="text" value="" id="departmentId"/>
                    员工编号：
                    <input style="width: 45px;" type="text" value="" id="crmId"/>
                    员工密码：
                    <input style="width: 45px;" type="password" id="pwd" value=""/>
                    </span>
                    token：
                    <input style="width: 120px;" type="text" id="token" value="" />
                    绑定电话：
                    <input style="width: 80px;" type="text" value="" id="bindTel"/>
                    电话类型：
                    <!--<span>-->
                    <select id="bindType" onchange="judgeBindTelType()">
                        <option value="1" selected>电话号码</option>
                        <option value="2">分机号码</option>
                        <option value="3">软电话</option>
                    </select>
                    <!--</span>-->
                        <span style="display:none; float:left;" id="sipSpan">
                            软电话IP：<input id="sipIp" type="text" value=""/>
                            软电话密码：<input id="sipPwd" type="text" value=""/>
                        </span>
                    初始状态：
                    <select id="initStatus" >
                        <option value="1">空闲</option>
                        <option value="2">置忙</option>
                    </select>
                    转写:
                    <select id="cdrIsAsr" >
                        <option value="1" selected>开启</option>
                        <option value="0">关闭</option>
                    </select>
                    <input id="loginButton" type="button" value="登录" onclick="loginDualCloudPlatform()" />
                    <input type="button" value="退出" onclick="logout()" />
                    <input type="button" value="退出并解绑" onclick="logoutAndunBund()" />
                </b>
                </span>
                </div>
            </td>
        </tr>
    </table>
</div>

<div id="dialog" style="display: none;">
    <div>
        <table align="center">
            <tbody>
            <tr><td style="float:left;">请输入号码：</td>
                <td style="float:right;">
                    <input type="text" id="phone_num" onkeyup="SelectTip(0)"
                           onkeyup="this.value=this.value.replace(/\D/g,'')"  onafterpaste="this.value=this.value.replace(/\D/g,'')"/>
                    <span id="selectInput" style="display: none;">
                        <select name="selectInput" id="sdemo" style="width:150px;" size=10 onchange="sdemoChange(options[selectedIndex].text)">
                        </select>
                    </span>
                </td>
            </tr>
            <tr id="dialogDisplayNumberInput">
                <td style="float:left;margin-top:8px;">客户侧外显号码：</td>
                <td style="float:right;margin-top:8px;">
                    <input style="width:120px;" type="text" id="phone_obClid"
                           onkeyup="this.value=this.value.replace(/\D/g,'')"  onafterpaste="this.value=this.value.replace(/\D/g,'')" />
                </td>
            </tr>
            <tr id="dialogDisplayAreaCodeInput" style="display: none">
                <td style="float:left;margin-top:8px;">外显区号：</td>
                <td style="float:right;margin-top:8px;">
                    <input style="width:120px;" type="text" id="phone_obClid_area_code"
                           onkeyup="this.value=this.value.replace(/\D/g,'')"  onafterpaste="this.value=this.value.replace(/\D/g,'')" />
                </td>
            </tr>
            <tr id="dialogSelect"><td style="float:left;">&nbsp;呼叫类型：</td>
                <td style="float:right;">
                    <select id="consultInput" onchange="consultSelectDiv" c style="float:right;">
                        <!--<option value="0">普通电话</option><option value="1">座席号</option><option value="2">分机号</option>-->
                    </select>
                </td>
            </tr>
            <tr id="dialogSelectTel"><td style="float:left;">&nbsp;在线空闲座席：</td>
                <td style="float:right;">
                    <select id="onlineIdleInput" style="float:right;width:142px;">
                    </select>
                </td>
            </tr>
            <tr id="dialogSelectIvr"><td style="float:left;">&nbsp;IVR列表：</td>
                <td style="float:right;">
                    <select id="ivrRootInput" style="width:70px;"></select>
                    <select id="ivrChildInput" style="width:70px;"></select>
                </td>
            </tr>
            <tr id="axb_telA" style="display: none;">
                <td  style="float:left;">telA号码:&nbsp;&nbsp;</td>
                <td  style="float:left;"><input type="text" id="axb_telA_num"  onkeyup="this.value=this.value.replace(/\D/g,'')"  onafterpaste="this.value=this.value.replace(/\D/g,'')"/></td>
            </tr>
            <tr id="axb_telX" style="display: none;">
                <td  style="float:left;">telX号码:&nbsp;&nbsp;</td>
                <td  style="float:left;"><input type="text" id="axb_telX_num"  onkeyup="this.value=this.value.replace(/\D/g,'')"  onafterpaste="this.value=this.value.replace(/\D/g,'')"/></td>
            </tr>
            <tr id="axb_telX_group" style="display: none;">
                <td  style="float:left;">telX号码组:&nbsp;&nbsp;</td>
                <td  style="float:left;"><input type="text" id="axb_telX_group_val" /></td>
            </tr>
            <tr>
                <td style="float:left;margin-left:50px; " id="dialogCallBtn">
                    <input id="dialogButtonName" type="button" value="呼叫"/>&nbsp;&nbsp;&nbsp;</td>
                <td style="float:left;" id="dialogCancelBtn">
                    <input id="dialogCancel" type="button" value="取消" /></td>
            </tr>
            </tbody>
        </table>
    </div>
</div>

<div class="floatWin" id="consultDialog" style="display: none; width: 245px; height: 100px;" >
    <div class="fwIitle">
        <h3 class="mouseDrag_title">咨询</h3>
        <a class="closeBtn mouseDrag_title_close" onclick="consoluDialogHide();"></a>
    </div>
    <div class="fwCont">
        <div style="padding:5px;text-align: center">
            <table border="0" cellpadding="0" cellspacing="0" width="230">
                <tbody>
                <tr height="20">
                    <td width="20" align="right"><input name="consultPhoneType" type="radio" value="0" checked="checked" style="margin-bottom:1px;"></td>
                    <td width="30" align="left">电话</td><td width="20" align="right"><input name="consultPhoneType" type="radio" value="1" style="margin-bottom:1px;"></td>
                    <td width="40" align="left">座席号</td><td width="20" align="right"><input name="consultPhoneType" type="radio" value="2" style="margin-bottom:1px;"></td>
                    <td width="30" align="left">分机</td>
                </tr>
                <tr id="consultTel_tr" height="20">
                    <td colspan="6" align="center"> 请输入：<input type="text" value="" id="consultTel_text">
                    </td>
                </tr>
                <tr height="20" id="onlineFreeCno_tr" style="display: none;">
                    <td colspan="6" align="center">在线空闲座席：
                        <input type="text" style="width:120px;" value="" id="onlineFreeCno_select">
                        <!--<select id="onlineFreeCno_select" style="float:right;width:142px;">
                        </select>-->
                    </td>
                </tr>
                </tbody>
            </table>
        </div>
    </div>
    <div class="clear"></div>
    <div class="fwFooot" style="height:25px; line-height:20px; position:relative; border-top:1px solid #dedede; background:#f9f9f9;">
        <div class="winBtn"><a class="greenbtn" id="consultDialogButton">确定</a></div>
    </div>
</div>

<div class="floatWin" id="transferDialog" style="display: none; width: 245px; height: 100px;" >
    <div class="fwIitle">
        <h3 class="mouseDrag_title">转接</h3>
        <a class="closeBtn mouseDrag_title_close" onclick="transferDialogHide();"></a>
    </div>
    <div class="fwCont">
        <div style="padding:5px;text-align: center">
            <table border="0" cellpadding="0" cellspacing="0" width="250">
                <tbody>
                <tr height="20">
                    <td width="55"><input name="transferPhoneType" type="radio" value="0" checked="checked" style="margin-bottom:1px;">普通电话</td>
                    <td width="55"><input name="transferPhoneType" type="radio" value="1" style="margin-bottom:1px;">座席号码</td>
                    <td width="55"><input name="transferPhoneType" type="radio" value="3" style="margin-bottom:1px;">IVR</td>
                </tr>
                <tr id="transferTel_tr" height="20">
                    <td colspan="6" align="center"> 请输入：<input type="text" value="" id="transferTel_text">
                    </td>
                </tr>
                <tr height="20" id="transferOnlineFreeCno_tr" style="display: none;">
                    <td colspan="6" align="center"> 请输入：<input type="text" value="" id="transferOnlineFreeCno_text">
                    </td>
                </tr>
                <tr id="transferSelectIvr_tr" style="display: none;">
                    <td style="">
                        <select id="ivrTransferType" style="width:70px;">
                            <option value="1" selected>IVR节点：</option>
                            <option value="2">IVR名称：</option>
                        </select>
                    </td>
                    <td style="width:78px;">
                        <input type="text" value="" style="width:60px;" id="transferIvrRoot_text" />
                    </td>
                    <td style="width:106px;">
                        Path：<input type="text" value="" style="width:60px;" id="transferIvrChild_text" />
                    </td>
                </tr>
                </tbody>
            </table>
        </div>
    </div>
    <div class="clear"></div>
    <div class="fwFooot" style="height:25px; line-height:20px; position:relative; border-top:1px solid #dedede; background:#f9f9f9;">
        <div class="winBtn"><a class="greenbtn" id="transferDialogButton">确定</a></div>
    </div>
</div>


<div class="floatWin" id="interactDialog" style="display: none; width: 245px; height: 80px;" >
    <div class="fwIitle">
        <h3 class="mouseDrag_title">交互</h3>
        <a class="closeBtn mouseDrag_title_close" onclick="interactDialogHide();"></a>
    </div>
    <div class="fwCont">
        <div style="padding:5px;text-align: center">
            <table border="0" cellpadding="0" cellspacing="0" width="250">
                <tbody>
                <tr id="interactIvr_tr">
                    <td style="">
                        <select id="ivrInteractType" style="width:70px;">
                            <option value="0" selected>IVR节点：</option>
                            <option value="1">IVR名称：</option>
                        </select>
                    </td>
                    <!--<td style="width: 60px;"><div>IVR节点：</div></td>-->
                    <td>
                        <input type="text" value="" style="width:70px;" id="interactIvrRoot_text">
                    </td>
                    <td style=""><div>Path：</div></td>
                    <td>
                        <input type="text" value="" style="width:70px;" id="interactIvrChild_text">
                    </td>
                </tr>
                </tbody>
            </table>
        </div>
    </div>
    <div class="clear"></div>
    <div class="fwFooot" style="height:25px; line-height:20px; position:relative; border-top:1px solid #dedede; background:#f9f9f9;">
        <div class="winBtn"><a class="greenbtn" id="interactDialogButton">确定</a></div>
    </div>
</div>

<div id="changeBindTelDialog" style="display: none;">
    <div>
        <br>
        <table align="center">
            <tbody>
            <tr><td style="">绑定电话：</td>
                <td style="">
                    <input type="text" style="width: 150px;" id="agentTel" />
                </td>
            </tr>
            <tr>
                <td width="100" height="20">绑定电话类型：</td>
                <td>
   		            <span style="float:left">
                        <select id="agentTelType" value="1">
                            <option value="1" selected>普通电话</option>
                            <option value="2">分机号码</option>
                        </select>
                    </span>
                </td>
            </tr>
            <tr>
                <td style="">
                    <br>
                    <input style="margin-left:60px;" id="telDialogButtonName" type="button" value="确认"/>
                </td>
                <td style="">
                    <br>
                    <input style="margin-left:60px;" id="telDialogCancel" type="button" value="取消"/>
                </td>
            </tr>
            </tbody>
        </table>
    </div>
</div>
<!-- 移动坐席、办公坐席 -->
<div id="MobileOfficeInputDialog" style="display: none;background: white;border-radius:3px;box-shadow:0px 0px 10px #111; border:1px solid #F0F0F0;height:110px;width: 500px;position: absolute;top: 2%;left: 38%;z-index: 5;">
    <div id="MobileOfficeInputTable">
        <br>
        <table align="center">
            <tbody>
            <tr><td style="" id="MobileOfficeInputTitle">绑定电话：</td>
                <td style="">
                    <input type="text" style="width: 150px;" id="mobileOfficeTel" />
                </td>
            </tr>
            <tr id="officeTelSelect" style="display: none;">
                <td width="100" height="20">绑定电话类型：</td>
                <td>
   		            <span style="float:left">
                        <select id="officeTelType" >
                            <option value="3" selected>分机号码</option>
                            <option value="4">软电话</option>
                        </select>
                    </span>
                </td>
            </tr>
            <tr>
                <td style="">
                    <br>
                    <input style="margin-left:60px;" id="mobileOfficeTelButton" type="button" value="确认"/>
                </td>
                <td style="">
                    <br>
                    <input style="margin-left:60px;" id="mobileOfficeTelCancel" type="button" value="取消"/>
                </td>
            </tr>
            </tbody>
        </table>
    </div>
    <!-- 选则框 -->
    <div id="officeRadioButtonContainer" style="display:none; padding:5px;">
        <div id="officeRadionButtonDiv">

        </div>
        <div style="margin-top:5px">
            <input style="margin-left:60px;" id="officeRadionButton" type="button" value="确认"/>
            <input style="margin-left:60px;" id="officeRadionCancel" type="button" value="取消"/>
        </div>
    </div>
</div>
<!-- 移动坐席 end -->

<div id="breakLineDialog" style="display: none;">
    <div>
        <br>
        <div id="breakLinkInfo"><span></span></div>
        <br><br>
        <div id="breakLinkDiv" align="right"></div>
    </div>
</div>

<div id="dialogOver"></div>

</body>

<script>
    (function () {

        function getCookie(c_name) {
            if (document.cookie.length > 0) {
                c_start = document.cookie.indexOf(c_name + "=")
                if (c_start != -1) {
                    c_start = c_start + c_name.length + 1
                    c_end = document.cookie.indexOf(";", c_start)
                    if (c_end == -1) c_end = document.cookie.length
                    return unescape(document.cookie.substring(c_start, c_end))
                }
            }
            return ""
        }

        var loginType = getCookie("loginType") == "" ? "1" : getCookie("loginType");
        var bindTel = getCookie("bindTel") == "" ? "" : getCookie("bindTel");
        var bindType = getCookie("bindType") == "" ? "1" : getCookie("bindType");
        var loginStatus = getCookie("loginStatus") == "" ? "1" : getCookie("loginStatus");
        var token = getCookie("token") == "" ? "" : getCookie("token");
        var cdrIsAsr = getCookie("cdrIsAsr") == "" ? "1" : getCookie("cdrIsAsr");

        //document.getElementById("loginType").value = loginType;
        for (var i = 0; i < document.getElementById("loginType").options.length; i++) {
            if (loginType == document.getElementById("loginType").options[i].value) {
                document.getElementById("loginType").options[i].selected = true;
                break;
            }
        }

        if (loginType == "1") {
            var departmentId = getCookie("departmentId") == "" ? "" : getCookie("departmentId");
            var crmId = getCookie("crmId") == "" ? "" : getCookie("crmId");
            var pwd = getCookie("pwd") == "" ? "" : getCookie("pwd");

            document.getElementById("departmentId").value = departmentId;
            document.getElementById("crmId").value = crmId;
            document.getElementById("pwd").value = pwd;

            document.getElementById("enterpriseTR").style.display = "none";
            document.getElementById("departmentTR").style.display = "";
        }
        else {
            var enterpriseId = getCookie("enterpriseId") == "" ? "" : getCookie("enterpriseId");
            var cno = getCookie("cno") == "" ? "" : getCookie("cno");

            document.getElementById("enterpriseId").value = enterpriseId;
            document.getElementById("cno").value = cno;
            document.getElementById("token").value = token;

            document.getElementById("departmentTR").style.display = "none";
            document.getElementById("enterpriseTR").style.display = "";
        }
        document.getElementById("token").value = token;
        document.getElementById("bindTel").value = bindTel;
        document.getElementById("bindType").value = bindType;
        document.getElementById("initStatus").value = loginStatus;
        document.getElementById("cdrIsAsr").value = cdrIsAsr;

    }());
</script>

</html>
